package com.awanp3.nimbus.base.domain.bo;

import com.awanp3.nimbus.base.domain.BaseMaterial;
import com.awanp3.nimbus.common.core.validate.AddGroup;
import com.awanp3.nimbus.common.core.validate.EditGroup;
import com.awanp3.nimbus.common.mybatis.core.domain.BaseEntity;
import io.github.linpeilie.annotations.AutoMapper;
import lombok.Data;
import lombok.EqualsAndHashCode;
import jakarta.validation.constraints.*;

/**
 * 物料业务对象 base_material
 *
 * @author 20014170
 * @date 2025-09-08
 */
@Data
@EqualsAndHashCode(callSuper = true)
@AutoMapper(target = BaseMaterial.class, reverseConvertGenerate = false)
public class BaseMaterialBo extends BaseEntity {

    /**
     * 物料ID
     */
    private Long materialId;

    /**
     * 物料编码
     */
    @NotBlank(message = "物料编码不能为空", groups = { AddGroup.class, EditGroup.class })
    private String materialCode;

    /**
     * 物料描述
     */
    @NotBlank(message = "物料描述不能为空", groups = { AddGroup.class, EditGroup.class })
    private String materialDesc;

    /**
     * 物料类型
     */
    @NotBlank(message = "物料类型不能为空", groups = { AddGroup.class, EditGroup.class })
    private String materialType;

    /**
     * 产业编码
     */
    @NotBlank(message = "产业编码不能为空", groups = { AddGroup.class, EditGroup.class })
    private String industryCode;

    /**
     * 产业名称
     */
    private String industryName;

    /**
     * 工厂编码
     */
    @NotBlank(message = "工厂编码不能为空", groups = { AddGroup.class, EditGroup.class })
    private String plantCode;

    /**
     * 长度
     */
    @NotNull(message = "长度不能为空", groups = { AddGroup.class, EditGroup.class })
    private Integer length;

    /**
     * 宽度
     */
    @NotNull(message = "宽度不能为空", groups = { AddGroup.class, EditGroup.class })
    private Integer width;

    /**
     * 高度
     */
    @NotNull(message = "高度不能为空", groups = { AddGroup.class, EditGroup.class })
    private Integer height;

    /**
     * 状态
     */
    @NotBlank(message = "状态不能为空", groups = { AddGroup.class, EditGroup.class })
    private String status;


}
